Skip to content

fix: Use instance origin for waiting forms and webhooks CORS headers instead of wildcard#2082

Open
everettbu wants to merge 2 commits intomasterfrom
node-4138-community-issue-form-trigger-always-loop
Open

fix: Use instance origin for waiting forms and webhooks CORS headers instead of wildcard#2082
everettbu wants to merge 2 commits intomasterfrom
node-4138-community-issue-form-trigger-always-loop

Conversation

@everettbu
Copy link
Copy Markdown

Mirror of n8n-io/n8n#26133
Original author: michael-radency


Summary

Waiting webhooks(and forms) could break for users behind reverse proxies that strip Access-Control-Allow-Origin: * responses

Fix: applyCors now uses the configured instance origin instead of * when the request has no real origin (CSP-sandboxed form pages). The origin is derived from WEBHOOK_URL (falls back to N8N_HOST/N8N_PROTOCOL/N8N_PORT).

Required: WEBHOOK_URL must be set to the public-facing n8n URL for the fix to take effect

Related Linear tickets, Github issues, and Community forum posts

https://linear.app/n8n/issue/NODE-4138/community-issue-form-trigger-always-loop
fixes n8n-io/n8n#23262

Review / Merge checklist

  • PR title and summary are descriptive. (conventions)
  • Docs updated or follow-up ticket created.
  • Tests included.
  • PR Labeled with release/backport (if the PR is an urgent fix that needs to be backported)

@everettbu everettbu added the n8n team Authored by the n8n team label Feb 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

n8n team Authored by the n8n team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Form trigger always looping

2 participants